package com.jspxcms.core.service;

import com.jspxcms.core.domain.User;
import com.jspxcms.core.domain.UserDetail;
import org.springframework.data.jpa.repository.Query;

public interface UserDetailService {
    public UserDetail get(Integer id);

    public UserDetail save(UserDetail detail, User user, String ip);

    public UserDetail update(UserDetail detail);

    /**
     * 加减积分
     *
     * @param id
     * @param score
     * @return
     */
    public boolean updateScore(Integer id, Integer score);


    /**
     * @param userId
     * @param type
     * @param score
     * @return
     */
    public boolean updateScore(Integer userId, Integer type, Integer score);


    public void updateHospital(Integer userId, String hospital);

}
